from langchain_core.prompts import ChatPromptTemplate

from model_utils import getLLM

llm = getLLM()

template = ChatPromptTemplate(
    [("system","你是一名优秀的翻译官，将用户的信息翻译成{language}"),
    ("human","{content}")
])

# msg = template.invoke({"language":"英语","content":"我爱你三千遍"})
msg = template.format(language="英语",content="我爱你")
r = llm.invoke(msg)
print(r)